\(\int \frac {(g \sec (e+f x))^{3/2}}{\sqrt {a+b \sec (e+f x)} (c+d \sec (e+f x))} \, dx\) [283]

   Optimal result
   Rubi [A] (verified)
   Mathematica [A] (verified)
   Maple [C] (verified)
   Fricas [F(-1)]
   Sympy [F]
   Maxima [F]
   Giac [F]
   Mupad [F(-1)]

Optimal result

Integrand size = 39, antiderivative size = 83 \[ \int \frac {(g \sec (e+f x))^{3/2}}{\sqrt {a+b \sec (e+f x)} (c+d \sec (e+f x))} \, dx=\frac {2 g \sqrt {\frac {b+a \cos (e+f x)}{a+b}} \operatorname {EllipticPi}\left (\frac {2 c}{c+d},\frac {1}{2} (e+f x),\frac {2 a}{a+b}\right ) \sqrt {g \sec (e+f x)}}{(c+d) f \sqrt {a+b \sec (e+f x)}} \]

[Out]

2*g*(cos(1/2*f*x+1/2*e)^2)^(1/2)/cos(1/2*f*x+1/2*e)*EllipticPi(sin(1/2*f*x+1/2*e),2*c/(c+d),2^(1/2)*(a/(a+b))^
(1/2))*((b+a*cos(f*x+e))/(a+b))^(1/2)*(g*sec(f*x+e))^(1/2)/(c+d)/f/(a+b*sec(f*x+e))^(1/2)

Rubi [A] (verified)

Time = 0.73 (sec) , antiderivative size = 83, normalized size of antiderivative = 1.00, number of steps used = 3, number of rules used = 3, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.077, Rules used = {4060, 2886, 2884} \[ \int \frac {(g \sec (e+f x))^{3/2}}{\sqrt {a+b \sec (e+f x)} (c+d \sec (e+f x))} \, dx=\frac {2 g \sqrt {g \sec (e+f x)} \sqrt {\frac {a \cos (e+f x)+b}{a+b}} \operatorname {EllipticPi}\left (\frac {2 c}{c+d},\frac {1}{2} (e+f x),\frac {2 a}{a+b}\right )}{f (c+d) \sqrt {a+b \sec (e+f x)}} \]

[In]

Int[(g*Sec[e + f*x])^(3/2)/(Sqrt[a + b*Sec[e + f*x]]*(c + d*Sec[e + f*x])),x]

[Out]

(2*g*Sqrt[(b + a*Cos[e + f*x])/(a + b)]*EllipticPi[(2*c)/(c + d), (e + f*x)/2, (2*a)/(a + b)]*Sqrt[g*Sec[e + f
*x]])/((c + d)*f*Sqrt[a + b*Sec[e + f*x]])

Rule 2884

Int[1/(((a_.) + (b_.)*sin[(e_.) + (f_.)*(x_)])*Sqrt[(c_.) + (d_.)*sin[(e_.) + (f_.)*(x_)]]), x_Symbol] :> Simp
[(2/(f*(a + b)*Sqrt[c + d]))*EllipticPi[2*(b/(a + b)), (1/2)*(e - Pi/2 + f*x), 2*(d/(c + d))], x] /; FreeQ[{a,
 b, c, d, e, f}, x] && NeQ[b*c - a*d, 0] && NeQ[a^2 - b^2, 0] && NeQ[c^2 - d^2, 0] && GtQ[c + d, 0]

Rule 2886

Int[1/(((a_.) + (b_.)*sin[(e_.) + (f_.)*(x_)])*Sqrt[(c_.) + (d_.)*sin[(e_.) + (f_.)*(x_)]]), x_Symbol] :> Dist
[Sqrt[(c + d*Sin[e + f*x])/(c + d)]/Sqrt[c + d*Sin[e + f*x]], Int[1/((a + b*Sin[e + f*x])*Sqrt[c/(c + d) + (d/
(c + d))*Sin[e + f*x]]), x], x] /; FreeQ[{a, b, c, d, e, f}, x] && NeQ[b*c - a*d, 0] && NeQ[a^2 - b^2, 0] && N
eQ[c^2 - d^2, 0] &&  !GtQ[c + d, 0]

Rule 4060

Int[(csc[(e_.) + (f_.)*(x_)]*(g_.))^(3/2)/(Sqrt[csc[(e_.) + (f_.)*(x_)]*(b_.) + (a_)]*(csc[(e_.) + (f_.)*(x_)]
*(d_.) + (c_))), x_Symbol] :> Dist[g*Sqrt[g*Csc[e + f*x]]*(Sqrt[b + a*Sin[e + f*x]]/Sqrt[a + b*Csc[e + f*x]]),
 Int[1/(Sqrt[b + a*Sin[e + f*x]]*(d + c*Sin[e + f*x])), x], x] /; FreeQ[{a, b, c, d, e, f, g}, x] && NeQ[b*c -
 a*d, 0] && NeQ[a^2 - b^2, 0]

Rubi steps \begin{align*} \text {integral}& = \frac {\left (g \sqrt {b+a \cos (e+f x)} \sqrt {g \sec (e+f x)}\right ) \int \frac {1}{\sqrt {b+a \cos (e+f x)} (d+c \cos (e+f x))} \, dx}{\sqrt {a+b \sec (e+f x)}} \\ & = \frac {\left (g \sqrt {\frac {b+a \cos (e+f x)}{a+b}} \sqrt {g \sec (e+f x)}\right ) \int \frac {1}{\sqrt {\frac {b}{a+b}+\frac {a \cos (e+f x)}{a+b}} (d+c \cos (e+f x))} \, dx}{\sqrt {a+b \sec (e+f x)}} \\ & = \frac {2 g \sqrt {\frac {b+a \cos (e+f x)}{a+b}} \operatorname {EllipticPi}\left (\frac {2 c}{c+d},\frac {1}{2} (e+f x),\frac {2 a}{a+b}\right ) \sqrt {g \sec (e+f x)}}{(c+d) f \sqrt {a+b \sec (e+f x)}} \\ \end{align*}

Mathematica [A] (verified)

Time = 1.38 (sec) , antiderivative size = 83, normalized size of antiderivative = 1.00 \[ \int \frac {(g \sec (e+f x))^{3/2}}{\sqrt {a+b \sec (e+f x)} (c+d \sec (e+f x))} \, dx=\frac {2 g \sqrt {\frac {b+a \cos (e+f x)}{a+b}} \operatorname {EllipticPi}\left (\frac {2 c}{c+d},\frac {1}{2} (e+f x),\frac {2 a}{a+b}\right ) \sqrt {g \sec (e+f x)}}{(c+d) f \sqrt {a+b \sec (e+f x)}} \]

[In]

Integrate[(g*Sec[e + f*x])^(3/2)/(Sqrt[a + b*Sec[e + f*x]]*(c + d*Sec[e + f*x])),x]

[Out]

(2*g*Sqrt[(b + a*Cos[e + f*x])/(a + b)]*EllipticPi[(2*c)/(c + d), (e + f*x)/2, (2*a)/(a + b)]*Sqrt[g*Sec[e + f
*x]])/((c + d)*f*Sqrt[a + b*Sec[e + f*x]])

Maple [C] (verified)

Result contains complex when optimal does not.

Time = 7.46 (sec) , antiderivative size = 223, normalized size of antiderivative = 2.69

method result size
default \(-\frac {2 i g \sqrt {a +b \sec \left (f x +e \right )}\, \cos \left (f x +e \right ) \sqrt {g \sec \left (f x +e \right )}\, \left (2 c \operatorname {EllipticPi}\left (i \left (-\cot \left (f x +e \right )+\csc \left (f x +e \right )\right ), -\frac {c -d}{c +d}, i \sqrt {\frac {a -b}{a +b}}\right )-c \operatorname {EllipticF}\left (i \left (-\cot \left (f x +e \right )+\csc \left (f x +e \right )\right ), \sqrt {-\frac {a -b}{a +b}}\right )-d \operatorname {EllipticF}\left (i \left (-\cot \left (f x +e \right )+\csc \left (f x +e \right )\right ), \sqrt {-\frac {a -b}{a +b}}\right )\right ) \sqrt {\frac {b +a \cos \left (f x +e \right )}{\left (a +b \right ) \left (\cos \left (f x +e \right )+1\right )}}}{f \left (c -d \right ) \left (c +d \right ) \left (b +a \cos \left (f x +e \right )\right ) \sqrt {\frac {1}{\cos \left (f x +e \right )+1}}}\) \(223\)

[In]

int((g*sec(f*x+e))^(3/2)/(c+d*sec(f*x+e))/(a+b*sec(f*x+e))^(1/2),x,method=_RETURNVERBOSE)

[Out]

-2*I*g/f/(c-d)/(c+d)*(a+b*sec(f*x+e))^(1/2)*cos(f*x+e)*(g*sec(f*x+e))^(1/2)*(2*c*EllipticPi(I*(-cot(f*x+e)+csc
(f*x+e)),-(c-d)/(c+d),I*((a-b)/(a+b))^(1/2))-c*EllipticF(I*(-cot(f*x+e)+csc(f*x+e)),(-(a-b)/(a+b))^(1/2))-d*El
lipticF(I*(-cot(f*x+e)+csc(f*x+e)),(-(a-b)/(a+b))^(1/2)))*(1/(a+b)*(b+a*cos(f*x+e))/(cos(f*x+e)+1))^(1/2)/(b+a
*cos(f*x+e))/(1/(cos(f*x+e)+1))^(1/2)

Fricas [F(-1)]

Timed out. \[ \int \frac {(g \sec (e+f x))^{3/2}}{\sqrt {a+b \sec (e+f x)} (c+d \sec (e+f x))} \, dx=\text {Timed out} \]

[In]

integrate((g*sec(f*x+e))^(3/2)/(c+d*sec(f*x+e))/(a+b*sec(f*x+e))^(1/2),x, algorithm="fricas")

[Out]

Timed out

Sympy [F]

\[ \int \frac {(g \sec (e+f x))^{3/2}}{\sqrt {a+b \sec (e+f x)} (c+d \sec (e+f x))} \, dx=\int \frac {\left (g \sec {\left (e + f x \right )}\right )^{\frac {3}{2}}}{\sqrt {a + b \sec {\left (e + f x \right )}} \left (c + d \sec {\left (e + f x \right )}\right )}\, dx \]

[In]

integrate((g*sec(f*x+e))**(3/2)/(c+d*sec(f*x+e))/(a+b*sec(f*x+e))**(1/2),x)

[Out]

Integral((g*sec(e + f*x))**(3/2)/(sqrt(a + b*sec(e + f*x))*(c + d*sec(e + f*x))), x)

Maxima [F]

\[ \int \frac {(g \sec (e+f x))^{3/2}}{\sqrt {a+b \sec (e+f x)} (c+d \sec (e+f x))} \, dx=\int { \frac {\left (g \sec \left (f x + e\right )\right )^{\frac {3}{2}}}{\sqrt {b \sec \left (f x + e\right ) + a} {\left (d \sec \left (f x + e\right ) + c\right )}} \,d x } \]

[In]

integrate((g*sec(f*x+e))^(3/2)/(c+d*sec(f*x+e))/(a+b*sec(f*x+e))^(1/2),x, algorithm="maxima")

[Out]

integrate((g*sec(f*x + e))^(3/2)/(sqrt(b*sec(f*x + e) + a)*(d*sec(f*x + e) + c)), x)

Giac [F]

\[ \int \frac {(g \sec (e+f x))^{3/2}}{\sqrt {a+b \sec (e+f x)} (c+d \sec (e+f x))} \, dx=\int { \frac {\left (g \sec \left (f x + e\right )\right )^{\frac {3}{2}}}{\sqrt {b \sec \left (f x + e\right ) + a} {\left (d \sec \left (f x + e\right ) + c\right )}} \,d x } \]

[In]

integrate((g*sec(f*x+e))^(3/2)/(c+d*sec(f*x+e))/(a+b*sec(f*x+e))^(1/2),x, algorithm="giac")

[Out]

integrate((g*sec(f*x + e))^(3/2)/(sqrt(b*sec(f*x + e) + a)*(d*sec(f*x + e) + c)), x)

Mupad [F(-1)]

Timed out. \[ \int \frac {(g \sec (e+f x))^{3/2}}{\sqrt {a+b \sec (e+f x)} (c+d \sec (e+f x))} \, dx=\int \frac {{\left (\frac {g}{\cos \left (e+f\,x\right )}\right )}^{3/2}}{\sqrt {a+\frac {b}{\cos \left (e+f\,x\right )}}\,\left (c+\frac {d}{\cos \left (e+f\,x\right )}\right )} \,d x \]

[In]

int((g/cos(e + f*x))^(3/2)/((a + b/cos(e + f*x))^(1/2)*(c + d/cos(e + f*x))),x)

[Out]

int((g/cos(e + f*x))^(3/2)/((a + b/cos(e + f*x))^(1/2)*(c + d/cos(e + f*x))), x)